﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using AifMessageHeaderEditor.Lib.File;

namespace AifMessageHeaderEditor.Lib.Tests
{
    [TestClass]
    public class FileTests
    {
        private string _directory = @"E:\SharedFolder\AifMessageHeaderEditor\AifMessageHeaderEditor.Lib.Tests";
        private string _fileName = "test.xml";
        public FileTests()
        {
            MessageFile.Instance.LoadDocument(_directory + "\\" + _fileName);
        }

        [TestMethod]
        public void TestTemplateFile()
        {
            Assert.AreEqual<String>(MessageFile.Instance.XmlFile.SourceFilename,
                _directory + "\\" + _fileName);
        }

        [TestMethod]
        public void TestDestinationDirectory()
        {
            Assert.AreEqual<String>(MessageFile.Instance.XmlFile.DestinationDirectory, _directory);
        }

        [TestMethod]
        public void TestFileOwner()
        {
            Assert.AreEqual<String>(MessageFile.Instance.XmlFile.FileOwner, @"dittgen-PC\dittgen");
        }

        [TestMethod]
        public void TestFileOwnerName()
        {
            Assert.AreEqual<String>(MessageFile.Instance.XmlFile.FileOwnerName, "dittgen");
        }

        //implement all

    }
}